<cfparam default="" name="PageType" />

<cfoutput>
	<!---HTML header, css links, js links, and page title--->
    #BASE.htmlHeader("", "", "Elder's Program - Reports")#
    <!---HTML header, css links, js links, and page title--->	
        
        <!---QUERIES.regionalcorpDistribution is set in showreport--->	  
        
        <cfif PageType EQ "PDF" >
            
            <cfdocument format="pdf"> 
      
                <h2>Regional Corp Distribution</h2>
                
                <table border="1" cellpadding="1" cellspacing="0">
                    <thead>
                        <tr>
                            <th>Regional Corp</th><th>Elder Count</th>
                        </tr>
                    </thead>
                    <tbody>
                        <cfloop query="QUERIES.regionalcorpDistribution">
                        <tr>
                            <td>#QUERIES.regionalcorpDistribution.RegionalCorp#</td>
                            <td align="center">#QUERIES.regionalcorpDistribution.ElderCount#</td>
                        </tr>
                        </cfloop>
                    </tbody>    
                </table> 
            </cfdocument>  
            
        <cfelse>  
         
            <h2>Regional Corp Distribution</h2>
                
                <table border="1" cellpadding="1" cellspacing="0">
                    <thead>
                        <tr>
                            <th>Regional Corp</th><th>Elder Count</th>
                        </tr>
                    </thead>
                    <tbody>
                        <cfloop query="QUERIES.regionalcorpDistribution">
                        <tr>
                            <td>#QUERIES.regionalcorpDistribution.RegionalCorp#</td>
                            <td align="center">#QUERIES.regionalcorpDistribution.ElderCount#</td>
                        </tr>
                        </cfloop>
                    </tbody>    
                </table> 
            
        </cfif>
        
    <!---HTML footer, closes html and body tags.  Any footer info goes here--->
    #BASE.htmlFooter()#
    <!---HTML footer, closes html and body tags.  Any footer info goes here--->
</cfoutput>